home *** CD-ROM | disk | FTP | other *** search
/ Cream of the Crop 20 / Cream of the Crop 20 (Terry Blount) (1996).iso / program / vol15n10.zip / MULTIL.ZIP / MLSRC.ZIP / MSDEV / PROJECTS / MLAUNCH / REGISTRY.H < prev    next >
C/C++ Source or Header  |  1996-03-11  |  739b  |  38 lines

  1. // Registry helper classes
  2. // (C)1996 By John Lam
  3.  
  4. // Class that represents a single value entry in the registry
  5.  
  6. class CRegistryValue
  7. {
  8. public:
  9.     CRegistryValue ();
  10.     ~CRegistryValue ();
  11.     
  12.     CRegistryValue (CString, CString);
  13.     CString m_strValue, m_strName;
  14. };
  15.  
  16. // Helper class that encapsulates a Registry key and allows for enumeration of 
  17. // the registry key
  18.  
  19. class CRegistryKey 
  20. {
  21. private:
  22.     CObList m_RegistryValues;
  23.     CString m_strRegistryKey;
  24.     POSITION m_pos;
  25.  
  26. public:
  27.     CRegistryKey ();
  28.     CRegistryKey (CString);
  29.     ~CRegistryKey ();
  30.  
  31.     // Access functions for internal linked list
  32.     BOOL GetNext(CRegistryValue*&);
  33.     CRegistryValue* GetAt(int);
  34.     void GotoHead();
  35.     void RemoveAt(int);
  36.     int GetCount();
  37. };
  38.